<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<!-- 
	Copyright (C) 2007, 2008, 2009, 2010, 2011. PARP Research Group.
	<http://perception.inf.um.es>
	University of Murcia, Spain.

	This file is part of the QVision library.

	QVision is free software: you can redistribute it and/or modify
	it under the terms of the GNU Lesser General Public License as
	published by the Free Software Foundation, version 3 of the License.

	QVision is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU Lesser General Public License for more details.

	You should have received a copy of the GNU Lesser General Public
	License along with QVision. If not, see <http://www.gnu.org/licenses/>.
-->

<html><head><meta http-equiv="content-Type" content="text/html;charset=UTF-8">
<title>QVision: Qt&#39;s Image, Video and Computer Vision Library</title>
<meta name="title" content="QVision" />
<meta name="dc.title" content="QVision" />
<meta name="url" content="http://perception.inf.um.es/QVision" />
<meta name="author" content="PARP Research Group - http://perception.inf.um.es" />
<meta name="revisit-after" content="30 DAYS"/>
<meta name="robots" content="index,follow"/>
<meta name="classification" content="*">
<meta name="rating" content="Safe For Kids">
<meta name="distribution" content="GLOBAL"/>
<meta name="description" content="Qt's Image, Video and Computer Vision Library"/>
<meta name="page-topic" content="Computer Vision research and prototype programming"/>
<meta name="geo.country" content="ES" />

<!--
Keywords:
By license:		open source, gnu, lgpl, gpl, free
By theme:		computer vision, image processing, robotics, programming, source, development
By usage:		library, toolkit, framework, prototype, application
By programming specs:	object oriented, c++, block programming, reusability, gui, graphical, parallel computing, high performance, GPU, prototyping
Interoperability with:	Qt, GSL, GNU Scientific library, OpenCV, CGAL, QWT, CUDA, mplayer, IPP, Intel Image Performance Primitives, blas, lapack
Functionallity:		image features, matrix algebra, projective geometry, mser, function minimization, function optimization, canny operator, harris operator, corner detection, performance evaluation, cpu usage, graphical interface
Main data-types:	matrix, vector, tensor, quaternion, image, polyline
Video sources:		webcam, camera, stream
Devices:		embedded, desktop computer, laptop, mini-laptop
Authors:		PARP research group. University of Murcia, Spain.
-->

<meta name="keywords" content="augmented reality, sfm, structure from motion, open source, gnu, lgpl, gpl, free, computer vision, image processing, robotics, programming, source, development, library, toolkit, framework, prototype, application, object oriented, c++, block programming, reusability, gui, graphical, parallel computing, high performance, GPU, prototyping, Qt, GSL, GNU Scientific library, OpenCV, CGAL, QWT, CUDA, mplayer, IPP, Intel Image Performance Primitives, blas, lapack, image features, matrix algebra, projective geometry, mser, function minimization, function optimization, canny operator, harris operator, corner detection, performance evaluation, cpu usage, graphical interface, matrix, vector, tensor, quaternion, image, polyline, webcam, camera, stream, embedded, desktop computer, laptop, mini-laptop, University of Murcia, Spain, PARP research group, vision por computador"/>
<meta http-equiv="keywords" content="augmented reality, sfm, structure from motion, open source, gnu, lgpl, gpl, free, computer vision, image processing, robotics, programming, source, development, library, toolkit, framework, prototype, application, object oriented, c++, block programming, reusability, gui, graphical, parallel computing, high performance, GPU, prototyping, Qt, GSL, GNU Scientific library, OpenCV, CGAL, QWT, CUDA, mplayer, IPP, Intel Image Performance Primitives, blas, lapack, image features, matrix algebra, projective geometry, mser, function minimization, function optimization, canny operator, harris operator, corner detection, performance evaluation, cpu usage, graphical interface, matrix, vector, tensor, quaternion, image, polyline, webcam, camera, stream, embedded, desktop computer, laptop, mini-laptop, University of Murcia, Spain, PARP research group, vision por computador"/>
<meta http-equiv="pragma" content="no-cache"/>
<meta http-equiv="title" content="QVision"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="tabs.css" rel="stylesheet" type="text/css" />
<link rel="shortcut icon" href="favicon.ico" />
</head><body>

<table width="100%"><tr>
	<td><a href="http://perception.inf.um.es/"><img src="parp.png" border="0" /> <big>PARP Research Group</big></a></td>
	<td align="right"><a href="http://www.um.es/"><big>Universidad de Murcia</big> <img src="um.png" border="0" /></a></td>
</tr></table>

<hr /><br />

<table width="95%" align="center"><tr><td>

<!-- Generated by Doxygen 1.6.3 -->
<script type="text/javascript"><!--
var searchBox = new SearchBox("searchBox", "search",false,'Search');
--></script>
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
          <form id="FSearchBox" action="search.php" method="get">
            <img id="MSearchSelect" src="search/search.png" alt=""/>
            <input type="text" id="MSearchField" name="query" value="Search" size="20" accesskey="S" 
                   onfocus="searchBox.OnSearchFieldFocus(true)" 
                   onblur="searchBox.OnSearchFieldFocus(false)"/>
          </form>
        </div>
      </li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>File&nbsp;Members</span></a></li>
    </ul>
  </div>
<h1>src/qvip/qvcomponenttree.h</h1><a href="qvcomponenttree_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment"> *      Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012. PARP Research Group.</span>
<a name="l00003"></a>00003 <span class="comment"> *      &lt;http://perception.inf.um.es&gt;</span>
<a name="l00004"></a>00004 <span class="comment"> *      University of Murcia, Spain.</span>
<a name="l00005"></a>00005 <span class="comment"> *</span>
<a name="l00006"></a>00006 <span class="comment"> *      This file is part of the QVision library.</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> *      QVision is free software: you can redistribute it and/or modify</span>
<a name="l00009"></a>00009 <span class="comment"> *      it under the terms of the GNU Lesser General Public License as</span>
<a name="l00010"></a>00010 <span class="comment"> *      published by the Free Software Foundation, version 3 of the License.</span>
<a name="l00011"></a>00011 <span class="comment"> *</span>
<a name="l00012"></a>00012 <span class="comment"> *      QVision is distributed in the hope that it will be useful,</span>
<a name="l00013"></a>00013 <span class="comment"> *      but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
<a name="l00014"></a>00014 <span class="comment"> *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span>
<a name="l00015"></a>00015 <span class="comment"> *      GNU Lesser General Public License for more details.</span>
<a name="l00016"></a>00016 <span class="comment"> *</span>
<a name="l00017"></a>00017 <span class="comment"> *      You should have received a copy of the GNU Lesser General Public</span>
<a name="l00018"></a>00018 <span class="comment"> *      License along with QVision. If not, see &lt;http://www.gnu.org/licenses/&gt;.</span>
<a name="l00019"></a>00019 <span class="comment"> */</span>
<a name="l00020"></a>00020 
<a name="l00021"></a>00021 <span class="preprocessor">#ifndef QVCOMPONENTTREE_H</span>
<a name="l00022"></a>00022 <span class="preprocessor"></span><span class="preprocessor">#define QVCOMPONENTTREE_H</span>
<a name="l00023"></a>00023 <span class="preprocessor"></span>
<a name="l00027"></a>00027 
<a name="l00028"></a>00028 <span class="preprocessor">#include &lt;stdio.h&gt;</span>
<a name="l00029"></a>00029 <span class="preprocessor">#include &lt;stdlib.h&gt;</span>
<a name="l00030"></a>00030 <span class="preprocessor">#include &lt;iostream&gt;</span>
<a name="l00031"></a>00031 
<a name="l00032"></a>00032 <span class="preprocessor">#include &lt;qvip.h&gt;</span>
<a name="l00033"></a>00033 
<a name="l00034"></a>00034 <span class="preprocessor">#define  NULL_NODE      256*256*256</span>
<a name="l00035"></a>00035 <span class="preprocessor"></span>
<a name="l00103"></a><a class="code" href="classQVComponentTree.html">00103</a> <span class="keyword">class </span><a class="code" href="classQVComponentTree.html" title="Image component tree data structure.">QVComponentTree</a>
<a name="l00104"></a>00104         {
<a name="l00105"></a>00105         <span class="keyword">public</span>:
<a name="l00119"></a>00119                 <a class="code" href="classQVComponentTree.html#ac807f5189700723202a4b5f120fd2e57" title="Constructs a component tree set, from a gray-scale image.">QVComponentTree</a>(<span class="keyword">const</span> <a class="code" href="classQVImage.html">QVImage&lt;uChar,1&gt;</a> &amp;image, <span class="keywordtype">bool</span> inverseTree= <span class="keyword">false</span>, <span class="keywordtype">bool</span> useAlternative = <span class="keyword">false</span>);
<a name="l00120"></a>00120 
<a name="l00123"></a><a class="code" href="classQVComponentTree.html#a2a94333317eb67e9d74e71fca6fc19b0">00123</a>                 <span class="keywordtype">bool</span> <a class="code" href="classQVComponentTree.html#a2a94333317eb67e9d74e71fca6fc19b0" title="Returns whether this tree is inverted or not.">isInverseTree</a>()<span class="keyword">    const           </span>{ <span class="keywordflow">return</span> inverseTree; }
<a name="l00124"></a>00124 
<a name="l00131"></a><a class="code" href="classQVComponentTree.html#a608bd4b04af5ad582c863c7dc225ad0d">00131</a>                 uInt &amp; <a class="code" href="classQVComponentTree.html#a608bd4b04af5ad582c863c7dc225ad0d" title="Returns index for the root node in the image.">rootNode</a>()                       { <span class="keywordflow">return</span> rootNodeID; }
<a name="l00132"></a>00132 
<a name="l00142"></a><a class="code" href="classQVComponentTree.html#a045219975a0145022d98c7fcf47642cb">00142</a>                 uInt &amp; <a class="code" href="classQVComponentTree.html#a045219975a0145022d98c7fcf47642cb" title="Returns horizontal coordinate for the seed point of a node, given it&amp;#39;s index...">seedX</a>(uInt index)                { <span class="keywordflow">return</span> nodes[index].seedX; }
<a name="l00143"></a>00143 
<a name="l00153"></a><a class="code" href="classQVComponentTree.html#ac763fa3f3de4beab5bdb072921965862">00153</a>                 uInt &amp; <a class="code" href="classQVComponentTree.html#ac763fa3f3de4beab5bdb072921965862" title="Returns vertical coordinate for the seed point of a node, given it&amp;#39;s index.">seedY</a>(uInt index)                { <span class="keywordflow">return</span> nodes[index].seedY; }
<a name="l00154"></a>00154 
<a name="l00161"></a><a class="code" href="classQVComponentTree.html#af6f964ef20bf880f7aab393ec829e575">00161</a>                 uChar &amp; <a class="code" href="classQVComponentTree.html#af6f964ef20bf880f7aab393ec829e575" title="Returns gray-scale value of the points at the vertex of a node.">firstThreshold</a>(uInt index)      { <span class="keywordflow">return</span> nodes[index].firstThreshold; }
<a name="l00162"></a>00162 
<a name="l00169"></a><a class="code" href="classQVComponentTree.html#ae1f6def9a17a983f3d2047eb564cc3ad">00169</a>                 uChar &amp; <a class="code" href="classQVComponentTree.html#ae1f6def9a17a983f3d2047eb564cc3ad" title="Returns gray-scale value of the points at the base of a node.">lastThreshold</a>(uInt index)       { <span class="keywordflow">return</span> nodes[index].lastThreshold; }
<a name="l00170"></a>00170 
<a name="l00174"></a><a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1">00174</a>                 uInt &amp; <a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1" title="Returns the number of child nodes for a node.">numChilds</a>(uInt index)            { <span class="keywordflow">return</span> nodes[index].numChilds; }
<a name="l00175"></a>00175 
<a name="l00179"></a><a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea">00179</a>                 uInt &amp; <a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea" title="Returns the index for the first of the childs of a node.">firstChild</a>(uInt index)           { <span class="keywordflow">return</span> nodes[index].child; }
<a name="l00180"></a>00180 
<a name="l00184"></a><a class="code" href="classQVComponentTree.html#a44625404b168bb90229d611d32a628e4">00184</a>                 uInt &amp; <a class="code" href="classQVComponentTree.html#a44625404b168bb90229d611d32a628e4" title="Returns the index for the next node in the list of childs, for a node.">nextSibling</a>(uInt index)          { <span class="keywordflow">return</span> nodes[index].sibling; }
<a name="l00185"></a>00185 
<a name="l00203"></a><a class="code" href="classQVComponentTree.html#a270428438cc9b604e9261cf3c741c217">00203</a>                 uInt *<a class="code" href="classQVComponentTree.html#a270428438cc9b604e9261cf3c741c217" title="Returns the accumulative histogram of the gray-level values of the pixels, for a...">area</a>(uInt index)                  { <span class="keywordflow">return</span> nodes[index].area; }
<a name="l00204"></a>00204 
<a name="l00207"></a><a class="code" href="classQVComponentTree.html#afecb92bc570b9389428b6da484794ad6">00207</a>                 uInt <a class="code" href="classQVComponentTree.html#afecb92bc570b9389428b6da484794ad6" title="Gets the number of total nodes in the tree.">getNumNodes</a>()<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> numNodes; }
<a name="l00208"></a>00208 
<a name="l00211"></a><a class="code" href="classQVComponentTree.html#a4b7630450cf7de6631aee95adf7d9612">00211</a>                 uInt <a class="code" href="classQVComponentTree.html#a4b7630450cf7de6631aee95adf7d9612" title="Gets the number of leaf nodes in the tree.">getLeafNodes</a>()<span class="keyword"> const       </span>{ <span class="keywordflow">return</span> leafNodes; }
<a name="l00212"></a>00212 
<a name="l00217"></a><a class="code" href="classQVComponentTree.html#acd3bca7b612187c099bae32386f323d5">00217</a>                 uInt <a class="code" href="classQVComponentTree.html#acd3bca7b612187c099bae32386f323d5" title="Gets the number of pixels processed by the tree construction.">getTotalPoints</a>()<span class="keyword"> const     </span>{ <span class="keywordflow">return</span> totalPoints; }
<a name="l00218"></a>00218 
<a name="l00219"></a>00219         <span class="keyword">private</span>:
<a name="l00220"></a>00220                 <span class="keywordtype">void</span> getComponentTree(<span class="keyword">const</span> <a class="code" href="classQVImage.html">QVImage&lt;uChar&gt;</a> &amp;image);
<a name="l00221"></a>00221 
<a name="l00222"></a>00222                 uInt numNodes, freePoints, totalPoints, leafNodes, rootNodeID, maxNodes;
<a name="l00223"></a>00223                 <span class="keywordtype">bool</span> inverseTree;
<a name="l00224"></a>00224 
<a name="l00226"></a>00226                 <span class="keywordtype">bool</span> &amp; closedNode(uInt index)           { <span class="keywordflow">return</span> nodes[index].closed; }
<a name="l00227"></a>00227 
<a name="l00228"></a>00228                 uInt newNode(uInt SeedX, uInt SeedY, uChar <a class="code" href="group__qvippTACO.html#gada5e790176ab9e695b9b70ae399ffb2b" title="Performs thresholding of an image using the specified level.">Threshold</a>)
<a name="l00229"></a>00229                         {
<a name="l00230"></a>00230                         uInt newNodeID = this-&gt;numNodes++;
<a name="l00231"></a>00231 
<a name="l00232"></a>00232                         <a class="code" href="classQVComponentTree.html#a045219975a0145022d98c7fcf47642cb" title="Returns horizontal coordinate for the seed point of a node, given it&amp;#39;s index...">seedX</a>(newNodeID) = SeedX;
<a name="l00233"></a>00233                         <a class="code" href="classQVComponentTree.html#ac763fa3f3de4beab5bdb072921965862" title="Returns vertical coordinate for the seed point of a node, given it&amp;#39;s index.">seedY</a>(newNodeID) = SeedY;
<a name="l00234"></a>00234                         <a class="code" href="classQVComponentTree.html#af6f964ef20bf880f7aab393ec829e575" title="Returns gray-scale value of the points at the vertex of a node.">firstThreshold</a>(newNodeID) = <a class="code" href="classQVComponentTree.html#ae1f6def9a17a983f3d2047eb564cc3ad" title="Returns gray-scale value of the points at the base of a node.">lastThreshold</a>(newNodeID) = Threshold;
<a name="l00235"></a>00235                         <a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea" title="Returns the index for the first of the childs of a node.">firstChild</a>(newNodeID) =  <a class="code" href="classQVComponentTree.html#a44625404b168bb90229d611d32a628e4" title="Returns the index for the next node in the list of childs, for a node.">nextSibling</a>(newNodeID) = NULL_NODE;
<a name="l00236"></a>00236                         <a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1" title="Returns the number of child nodes for a node.">numChilds</a>(newNodeID) = 0;
<a name="l00237"></a>00237                         <a class="code" href="classQVComponentTree.html#a270428438cc9b604e9261cf3c741c217" title="Returns the accumulative histogram of the gray-level values of the pixels, for a...">area</a>(newNodeID)[Threshold] = 0;
<a name="l00238"></a>00238                         closedNode(newNodeID) = <span class="keyword">false</span>;
<a name="l00239"></a>00239                         
<a name="l00240"></a>00240                         <span class="keywordflow">return</span> newNodeID;
<a name="l00241"></a>00241                         }
<a name="l00242"></a>00242 
<a name="l00243"></a>00243                 <span class="keywordtype">void</span> addChild(uInt ParentNodeID, uInt ChildNodeID)
<a name="l00244"></a>00244                         {
<a name="l00245"></a>00245                         <a class="code" href="classQVComponentTree.html#a44625404b168bb90229d611d32a628e4" title="Returns the index for the next node in the list of childs, for a node.">nextSibling</a>(ChildNodeID) = <a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea" title="Returns the index for the first of the childs of a node.">firstChild</a>(ParentNodeID);
<a name="l00246"></a>00246                         <a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea" title="Returns the index for the first of the childs of a node.">firstChild</a>(ParentNodeID) = ChildNodeID;
<a name="l00247"></a>00247                         <a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1" title="Returns the number of child nodes for a node.">numChilds</a>(ParentNodeID)++;
<a name="l00248"></a>00248                         }
<a name="l00249"></a>00249 
<a name="l00250"></a>00250                 <span class="keywordtype">void</span> mergeNodes(uInt actualNodeID, uInt vecinoNodeID)
<a name="l00251"></a>00251                         {
<a name="l00252"></a>00252                         uInt next, lastActualChildNodeID = <a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea" title="Returns the index for the first of the childs of a node.">firstChild</a>(actualNodeID);
<a name="l00253"></a>00253                         <span class="keywordflow">while</span> ((next=<a class="code" href="classQVComponentTree.html#a44625404b168bb90229d611d32a628e4" title="Returns the index for the next node in the list of childs, for a node.">nextSibling</a>(lastActualChildNodeID)) != NULL_NODE)
<a name="l00254"></a>00254                                 lastActualChildNodeID = next;
<a name="l00255"></a>00255 
<a name="l00256"></a>00256                         <a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1" title="Returns the number of child nodes for a node.">numChilds</a>(actualNodeID) += <a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1" title="Returns the number of child nodes for a node.">numChilds</a>(vecinoNodeID);
<a name="l00257"></a>00257                         <a class="code" href="classQVComponentTree.html#a44625404b168bb90229d611d32a628e4" title="Returns the index for the next node in the list of childs, for a node.">nextSibling</a>(lastActualChildNodeID) = <a class="code" href="classQVComponentTree.html#a6fd2408b5112230e515623c7084601ea" title="Returns the index for the first of the childs of a node.">firstChild</a>(vecinoNodeID);
<a name="l00258"></a>00258                         }
<a name="l00259"></a>00259 
<a name="l00260"></a>00260                 <span class="keyword">class </span>QVComponentTreeNode
<a name="l00261"></a>00261                         {
<a name="l00262"></a>00262                         <span class="keyword">public</span>:
<a name="l00263"></a>00263                                 uInt <a class="code" href="classQVComponentTree.html#a045219975a0145022d98c7fcf47642cb" title="Returns horizontal coordinate for the seed point of a node, given it&amp;#39;s index...">seedX</a>, <a class="code" href="classQVComponentTree.html#ac763fa3f3de4beab5bdb072921965862" title="Returns vertical coordinate for the seed point of a node, given it&amp;#39;s index.">seedY</a>;
<a name="l00264"></a>00264                                 uInt child, sibling, <a class="code" href="classQVComponentTree.html#a1f7a6e31ceac2e50e0b262e0ec4056d1" title="Returns the number of child nodes for a node.">numChilds</a>;
<a name="l00265"></a>00265                                 uChar <a class="code" href="classQVComponentTree.html#af6f964ef20bf880f7aab393ec829e575" title="Returns gray-scale value of the points at the vertex of a node.">firstThreshold</a>, <a class="code" href="classQVComponentTree.html#ae1f6def9a17a983f3d2047eb564cc3ad" title="Returns gray-scale value of the points at the base of a node.">lastThreshold</a>;
<a name="l00266"></a>00266                                 uInt <a class="code" href="classQVComponentTree.html#a270428438cc9b604e9261cf3c741c217" title="Returns the accumulative histogram of the gray-level values of the pixels, for a...">area</a>[256];
<a name="l00267"></a>00267                                 <span class="keywordtype">bool</span> closed;
<a name="l00268"></a>00268 
<a name="l00269"></a>00269                                 <span class="comment">/*bool operator==(const QVComponentTreeNode &amp;other) const</span>
<a name="l00270"></a>00270 <span class="comment">                                        {</span>
<a name="l00271"></a>00271 <span class="comment">                                        if (seedX != other.seedX)</span>
<a name="l00272"></a>00272 <span class="comment">                                                return false;</span>
<a name="l00273"></a>00273 <span class="comment">                                        if (seedY != other.seedY)</span>
<a name="l00274"></a>00274 <span class="comment">                                                return false;</span>
<a name="l00275"></a>00275 <span class="comment">                                        //if (child != other.child)</span>
<a name="l00276"></a>00276 <span class="comment">                                        //      return false;</span>
<a name="l00277"></a>00277 <span class="comment">                                        //if (sibling != other.sibling)</span>
<a name="l00278"></a>00278 <span class="comment">                                        //      return false;</span>
<a name="l00279"></a>00279 <span class="comment">                                        if (numChilds != other.numChilds)</span>
<a name="l00280"></a>00280 <span class="comment">                                                return false;</span>
<a name="l00281"></a>00281 <span class="comment">                                        if (firstThreshold != other.firstThreshold)</span>
<a name="l00282"></a>00282 <span class="comment">                                                return false;</span>
<a name="l00283"></a>00283 <span class="comment">                                        if (lastThreshold != other.lastThreshold)</span>
<a name="l00284"></a>00284 <span class="comment">                                                return false;</span>
<a name="l00285"></a>00285 <span class="comment">                                        for (int i = firstThreshold; i &lt; lastThreshold; i++)</span>
<a name="l00286"></a>00286 <span class="comment">                                                if (area[i] != other.area[i])</span>
<a name="l00287"></a>00287 <span class="comment">                                                        return false;</span>
<a name="l00288"></a>00288 <span class="comment">                                        return true;</span>
<a name="l00289"></a>00289 <span class="comment">                                        }*/</span>
<a name="l00290"></a>00290                         };
<a name="l00291"></a>00291 
<a name="l00292"></a>00292                 QVector&lt;QVComponentTreeNode&gt; nodes;
<a name="l00293"></a>00293 
<a name="l00294"></a>00294                 <span class="comment">//void testComponentTree(const QVImage&lt;uChar,1&gt; &amp;image, QVDisjointSet &amp;disjointSet);</span>
<a name="l00295"></a>00295         };
<a name="l00296"></a>00296 
<a name="l00297"></a>00297 <span class="preprocessor">#endif //IFNDEF</span>
</pre></div></div>
</td></tr></table>

<br /><hr><br />
<center><a href="http://perception.inf.um.es/QVision">QVision framework</a>.
<a href="http://perception.inf.um.es">PARP research group</a>.
Copyright &copy; 2007, 2008, 2009, 2010, 2011.</center>
<br />
</body>
</html>
